package cn.com.pajx.pajx_smart_platform.mvp.presenter;

import android.text.TextUtils;

import java.util.LinkedHashMap;

import cn.com.pajx.pajx_smart_platform.api.HttpApiService;

/**
 * Created by ruancw on 2023/04/03.
 */

public class GetDataPresenterImpl extends BasePresenter {
    //获取数据
    @SuppressWarnings("unchecked")
    public void getData(String url, LinkedHashMap<String, String> paramsMap, String tag, String progressMessage) {
        if (!TextUtils.isEmpty(progressMessage)) {
            mView.showProgress(progressMessage);
        }
        addSubscription(mModel.getObservable(HttpApiService.getInstance().getRemoteData(url, paramsMap), tag));
    }
}
